import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex);//vue的插件机制

export default new Vuex.Store({
  state: {
    // 自定义状态
    userInfo: {
	  nick_name:'',
	  profile:'https://img.js.design/assets/avatarImg/Small64dc7cecd5a27071584095111701915503632.png',
	  business_mobile: '',
	  business_id: '',
	  authority: 0,
	  authority_name: '',
	  id: 0
    }
  },
  mutations: {
    // 自定义状态变更函数
    increment(state) {
      state.userInfo = state
    }
  }
  // 可以添加 actions, getters 等其他选项
})
